package com.xcmg.department.service;

import com.xcmg.department.mapper.DepartMapper;
import com.xcmg.department.entity.Depart;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import javax.annotation.Resource;

@Service
public class DepartmentServicelmp implements DepartmentService{

    @Resource
    private DepartMapper departMapper;

    @Override
    public Depart findDepartById(long id) {
        return departMapper.selectById(id);
    }

    @Override
    public void insertDepartment(Depart depart) {

        int insert= departMapper.insert(depart);

    }

    @Override
    public void deleteDepartmentById(long id) {

        int del= departMapper.deleteById(id);

    }
}
